const INITIAL_STATE = {
	_id: '',
	avatar:
		'https://636c-cloud1-0g1tg2fnddbcfb9a-1325753704.tcb.qcloud.la/gaga-notebook/avatar/_default.jpg?sign=5503997c6d1b80d046349b4e1d272250&t=1714646654',
	follower: [],
	nickname: '',
	unionid: '',
	space: [],
	collection: [],
	subscription: [],
	follow: [],
}

export default function user(state = INITIAL_STATE, action) {
	switch (action.type) {
		case 'UPDATE_USER': {
			return { ...state, ...action.payload }
		}
		default:
			return state
	}
}
